<?php

abstract class Controller extends Base {
    protected $config;
	protected $view;
	protected $user;
	
	public function __construct()
	{
		
	}

	/**
	 * 响应用户请求前执行的操作
	 */
	public function __before()
	{
		$this->user = new User();
		$this->view = new View(PG('mod'));
	}

	/**
	 * 响应用户请求后的操作
	 */
	public function __after()
	{

	}

	public function __call($func, $args)
	{
		new UserError("你访问的页面不存在: ". G('mod') . "-" . $func);
	}
}